package com.qire.manhua.dialog;

import android.content.Context;
import android.view.LayoutInflater;
import android.view.View;

import com.qire.antsrouter.AntsRouter;
import com.qire.common.constant.Navigation;
import com.qire.common.support.base.BaseDialog;
import com.qire.manhua.R;
import com.qire.manhua.databinding.DialogTeensRestrictReadBinding;

import androidx.annotation.NonNull;

/**
 * 青少年模式限制阅读弹窗
 */
public class TeensRestrictReadDialog extends BaseDialog {

    private final DialogTeensRestrictReadBinding viewDataBinder;

    public TeensRestrictReadDialog(@NonNull Context context) {
        super(context, R.style.CustomDialog_Translucent);
        viewDataBinder = DialogTeensRestrictReadBinding.inflate(LayoutInflater.from(context));
        viewDataBinder.setTeensRestrictReadDialog(this);

        setContentView(viewDataBinder.getRoot());
        setCancelable(true);
    }

    public void disableBtnOnClick(View view) {
        AntsRouter.ROUTER.buildCard(Navigation.Page.TeensControlPanelPage).navigation();
        dismiss();
    }

    public void closeBtnOnClick(View view) {
        dismiss();
    }

}
